<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org" xmlns:sec="http://www.thymeleaf.org/thymeleaf-extras-springsecurity4">

<body th:fragment="navbar">
  <div class="row border-bottom">
    <nav class="navbar navbar-fixed-top" role="navigation" style="margin-bottom: 0">
      <div class="navbar-header">
      <a class="navbar-brand" style="color: #888;font-weight:700; padding: 20px 10px; margin-right:20px; height: auto;width:220px;"
          th:href="@{'/'}" th:text="${applicationTitle}">CLOUD</a>
<!--            <img alt="image" th:src="@{|${theme}/img/logo2.jpg|}" /> -->
        <!--         <form role="search" class="navbar-form-custom" method="post" action="#"> -->
        <!--           <div class="form-group"> -->
        <!--             <input type="text" placeholder="输入关键字搜索功能" class="form-control" name="top-search" id="top-search" /> -->
        <!--           </div> -->
        <!--         </form> -->
        <!-- <a class="navbar-minimalize minimalize-styl-2 btn btn-primary " href="#">
          <i class="fa fa-bars"></i>
        </a> -->
      </div>
      <ul class="nav navbar-top-links navbar-left" th:if="${topnavs!=null}">
        <li th:each="menu:${topnavs}" th:class="${(subsystem !=null && subsystem.id == menu.id)?'active':''}">
          <a th:href="@{|/app/${menu.id}#${menu.url==null?'':menu.url}|}">
            <i th:class="${#strings.isEmpty(menu.icon)?'':menu.icon}"></i>
            <span class="nav-label" th:text="${menu.name}"></span>
          </a>
        </li>
      </ul>
      <ul class="nav navbar-top-links navbar-right">
        <!-- <li>
          <span class="m-r-sm text-muted welcome-messÏage">欢迎使用供应链平台.</span>
        </li> -->
        <!--
        <li th:if="${!isProductionEnvironment}">
          <a th:href="@{/static/themes/inspinia/demo/index.html}" target="_blank">Inspinia</a>
        </li>
         -->
        <!-- <li class="dropdown">
          <a class="dropdown-toggle count-info" data-toggle="dropdown" href="#">
            <i class="fa fa-bell"></i>
            <span class="label label-primary">8</span>
          </a>
          <ul class="dropdown-menu dropdown-alerts">
            <li>
              <a href="mailbox.html">
                <div>
                  <i class="fa fa-envelope fa-fw"></i> You have 16 messages
                  <span class="pull-right text-muted small">4 minutes ago</span>
                </div>
              </a>
            </li>
            <li class="divider"></li>
            <li>
              <a href="profile.html">
                <div>
                  <i class="fa fa-twitter fa-fw"></i> 3 New Followers
                  <span class="pull-right text-muted small">12 minutes ago</span>
                </div>
              </a>
            </li>
            <li class="divider"></li>
            <li>
              <a href="grid_options.html">
                <div>
                  <i class="fa fa-upload fa-fw"></i> Server Rebooted
                  <span class="pull-right text-muted small">4 minutes ago</span>
                </div>
              </a>
            </li>
            <li class="divider"></li>
            <li>
              <div class="text-center link-block">
                <a href="notifications.html">
                  <strong>See All Alerts</strong>
                  <i class="fa fa-angle-right"></i>
                </a>
              </div>
            </li>
          </ul>
        </li> -->
        <li sec:authorize="isAuthenticated()">
          <a th:href="@{|/profile|}" style="padding:15px 10px;">
            <img alt="image" class="img-circle" style="height: 30px; width: 30px;" th:src="@{|${theme}/img/profile_small.jpg|}" src="/themes/inspinia/img/profile_small.jpg" />
            <b sec:authentication="name"></b>
          </a>
        </li>
        <li>
          <a th:href="@{/logout}">
            <i class="fa fa-sign-out"></i>退出
          </a>
        </li>
      </ul>
    </nav>
  </div>
</body>

</html>
